<?php
    include('./conn.php');

    $username=$_REQUEST['username'];
    $password=$_REQUEST['password'];

    $sql="UPDATE `users` SET `password` = '$password' WHERE `users`.`username` = '$username';";

    $result=$mysqli->query($sql);
    
    if($result){
        echo '{"haschange":true}';
    }else{
        echo '{"haschange":false}';
    }
    $mysqli->close();
?>